package com.itheima.area.service.impl;

import com.itheima.area.dao.CropDao;
import com.itheima.area.pojo.CustFarmlandCrop;
import com.itheima.area.service.CropService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @PackageName com.itheima.area.service.impl
 * @ProjectName Ceres-Work
 * @Created by Chanly on 2020/10/15 20:08
 **/
@Service
public class CropServiceImpl implements CropService {
    @Autowired
    private CropDao cropDao;
    @Override
    public List<CustFarmlandCrop> findAll() {
        return cropDao.selectAll();
    }

    @Override
    public void add(CustFarmlandCrop custFarmlandCrop) {
        cropDao.insert(custFarmlandCrop);
    }
}
